package com.zhengping.zpys.security.role;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Isolation;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import javax.crypto.BadPaddingException;

import java.util.List;

/**
 * @author xiaonuolen
 * @version 1.0
 * @date 2020/3/27 11:37
 */
@Service
public class RoleServiceImpl implements RoleService {

    @Autowired
    private RoleMapper roleMapper;

    @Override
    public List<Role> queryList(Role role) {
        return roleMapper.queryList(role);
    }

    @Override
    public Integer deleteList(Long[] roles) {

        return roleMapper.deleteList(roles);
    }

    @Override
    public Integer creatRole(Role role) {

        return roleMapper.creatRole(role);

    }

    @Override
    public Integer updateRole(Role role) {

        return roleMapper.updateRole(role);
    }

    @Override
    public Role queryRoleById(Long roleId) {
        return roleMapper.queryRoleById(roleId);
    }


}
